1. Field of the Art
The present invention relates in general to an electronic dictionary device, and more particularly to an arrangement of a memory incorporated in the device to store word data representative of multiple words and search means for scanning the memory to find the word data representative of input data entered through operator-controlled keys.
2. Related Art Statement
In a known dictionary memory storing word data which represent a host of words of a language, for example, a list of English words in an alphabetical order, word data corresponding to a desired word must be searched by scanning the dictionary memory from the beginning of the memory while checking the invididual sets of word data against the desired word to be searched. This type, of searching is not satisfactory in terms of searching time required.
In addition, a so-called "binary search" or "dichotomizing search" is known, wherein memory locations storing individual sets of word data are provided with respective data-identification pointers. In this binary search process, the data storage area of a memory is divided into two parts, one of which is rejected and the other of which is accepted, based on whether these parts contain the word data in question. The process is repeated on the accepted part until the desired word data is found in the corresponding memory location. This binary or dichotomizing search process is advantageous for its faster searching capability.
More specifically described, binary searching involves individual memory locations corresponding to alphabetically arranged different words are given respective addresses Nl through Nn, as illustrated in FIG. 1. In the first step of a binary search, the entire area of the memory defined by the first address Nl and the last address Nn is divided into two parts by locating an (not shown) address Nt intermediate between Nl and Nn. The intermediate address Nt is obtained as Nt =(Nl +Nn)/2. If the obtained value Nt is not a whole number or integer, the address number Nt is determined to be a value of the integer part of the value (Nl +Nn)/2 as obtained, plus 1. The word data stored at the intermediate address Nt is retrieved, and compared with the desired data (data representing a desired word). If the retrieved data is not identical to the desired data, a check is made as to whether the desired data is stored at an address number smaller than the intermediate address number Nt, or at an address number larger than the to address Nt. If the checking reveals that the desired data is stored at an address number smaller than the intermediate address number Nt, the first part of the memory between the first address Nl and the intermediate address Nt is further divided into two sections. On the other hand, if the desired data is found to be stored at an address number larger than the intermediate address number Nt, the second part of the memory between the intermediate address Nt and the last address Nn is divided into two sections. In dividing the first or second part into two sections, an address number intermediate between Nl and Nt or between Nt and Nn is obtained in the same manner as indicated above. Then, the data stored at the newly obtained intermediate address is retrieved for comparison with the desired data, to find one of the two sections that is assigned to contain the desired data. The above binary search process is repeated on the accepted part or section until the memory location storing the desired data has been found.
Although the binary search permits a faster searching operation, it requires that the individual memory locations identified by the respective addresses have the same storage capacity. Hence, all memory locations should have a storage capacity which is sufficient to store the longest word or words which are stored in the dictionary memory. In other words, the storage capacity of each memory location should correspond to the number of characters of the longest word or words. In this arrangement of the memory, the memory locations tend to have considerably large waste portions which are not used.
If a series of word data is successively stored end to end in alphabetical order in a dictionary memory, on the other hand, the total storage capacity required is reduced. In this case, however, it is impossible to practice the binary or dichotomizing search process, and extra searching time is required.